package gameversion

import (
	"wanyu/server/protogo/public"
)

const (
	// 版本前缀和后缀
	prefix = "1."
	suffix = ""
)

var gamesVersion = map[public.GameType]string{
	public.GameType_BRNN:  prefix + "01" + suffix,
	public.GameType_DDZ:   prefix + "01" + suffix,
	public.GameType_DZPK:  prefix + "01" + suffix,
	public.GameType_EBG:   prefix + "01" + suffix,
	public.GameType_ERMJ:  prefix + "01" + suffix,
	public.GameType_HBSL:  prefix + "01" + suffix,
	public.GameType_HHDZ:  prefix + "01" + suffix,
	public.GameType_JDNN:  prefix + "01" + suffix,
	public.GameType_LHD:   prefix + "01" + suffix,
	public.GameType_PDK:   prefix + "01" + suffix,
	public.GameType_QZNN:  prefix + "01" + suffix,
	public.GameType_SHBY:  prefix + "01" + suffix,
	public.GameType_ZJH:   prefix + "01" + suffix,
	public.GameType_DFDC:  prefix + "01" + suffix,
	public.GameType_XZDD:  prefix + "01" + suffix,
	public.GameType_FKDDZ: prefix + "01" + suffix,
	public.GameType_XLCH:  prefix + "01" + suffix,
	public.GameType_XZMJ:  prefix + "01" + suffix,
}

func GetVersion(gameType public.GameType) string {
	if version, ok := gamesVersion[gameType]; ok {
		return version
	}

	return "unkown game type"
}

func getAllVersions() map[public.GameType]string {
	return gamesVersion
}
